﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace WindowsFormsApplication1
{
    public class Car
    {
        public virtual void Drive()
        {
            MessageBox.Show("Virtual Car.Drive(): The car goes from LEFT to RIGHT -->");
        }

        public void Drive2()
        {
            MessageBox.Show("Not virtual Car.Drive2(): The car goes from LEFT to RIGHT -->");
        }
    }

    public class Car2 : Car
    {
        public override void Drive()
        {
            MessageBox.Show("Override Car2.Drive(): <-- The car goes from RIGHT to LEFT");
        }

        public void Drive2()
        {
            MessageBox.Show("Not override Car2.Drive2(): <-- The car goes from RIGHT to LEFT");
        }
    }
}
